package com.zwy.stack;

import java.util.concurrent.ExecutionException;

//栈
public interface Stack {
    //返回栈的大小
    public int getSize();
    //判断堆栈是否为空
    public boolean isEmpty();
    //数据元素e入栈
    public void push(Object e);
    //栈顶元素出栈
    public Object pop() throws Exception;
    //取栈顶元素
    public Object peek() throws  Exception;
}
